package com.lijian.client.feign;

import com.lijian.pojo.Order;
import com.lijian.pojo.OrderResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

@FeignClient(value = "order-service")
public interface OrderFeign {

    @PostMapping("/order/save")
    public void save(@RequestBody Order order);

    @GetMapping("/order/findAllByUId")
    public OrderResult findAllByUid(@RequestParam Integer page, @RequestParam Integer limit, @RequestParam Integer uid);

    @GetMapping("/order/findAllByState")
    public OrderResult findAllByState(@RequestParam Integer page, @RequestParam Integer limit);

    @PutMapping("/order/update/{id}")
    public void update(@PathVariable Integer id);
}
